package pl.prv.polanie.client.dto;

import com.google.gwt.user.client.rpc.IsSerializable;


/**
 * SubgroupDTO entity. @author MyEclipse Persistence Tools
 */

public class SubgroupDTO extends java.lang.Object implements IsSerializable {


    // Fields    

     private long id;
     private SubgroupTypeDTO subgroupType;
     private GroupDTO group;
     private String name;
     private Integer studentsNumber;


    // Constructors

    /** default constructor */
    public SubgroupDTO() {
    }

    
    /** full constructor */
    public SubgroupDTO(SubgroupTypeDTO subgroupType, GroupDTO group, String name, Integer studentsNumber) {
        this.subgroupType = subgroupType;
        this.group = group;
        this.name = name;
        this.studentsNumber = studentsNumber;
    }


	public long getId() {
		return id;
	}


	public void setId(long id) {
		this.id = id;
	}


	public SubgroupTypeDTO getSubgroupType() {
		return subgroupType;
	}


	public void setSubgroupType(SubgroupTypeDTO subgroupType) {
		this.subgroupType = subgroupType;
	}


	public GroupDTO getGroup() {
		return group;
	}


	public void setGroup(GroupDTO group) {
		this.group = group;
	}


	public String getName() {
		return name;
	}


	public void setName(String name) {
		this.name = name;
	}


	public Integer getStudentsNumber() {
		return studentsNumber;
	}


	public void setStudentsNumber(Integer studentsNumber) {
		this.studentsNumber = studentsNumber;
	}

	public String toLabel() {
		String r;
		r = name + " (" + subgroupType.getName() + ", " + studentsNumber + ") " + group.toLabel();
		return r;
	}





}